package com.share.design.observer;

/**
 * author:caifan
 * date:2020/2/4
 */
public class StudentEventListener implements BellEventListener {
    @Override
    public void heardBell(RingEvent event) {
        if (event.isSound()) {
            System.out.println("学生上课");
        } else {
            System.out.println("学生下课");
        }
    }
}
